import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '*',
    component: () => import('views/404/index.vue')
  },
  {
    path: '/error',
    component: () => import('views/404/error.vue')
  },
  { path: '/', redirect: '/nav' },
  {
		path: '/nav',
		name: 'nav',
		component: () => import('views/nav.vue'),
	},
  {
    path: '/zbuser',
    name: 'zbuser',
    component: () => import('views/index.vue')
  },
  {
    //通知公告
    path: '/notice/list',
    name: 'notice',
    component: () => import('views/notice/index.vue')
  },
  {
    //通知公告
    path: '/notice/search',
    name: 'noticeSearch',
    component: () => import('views/notice/search.vue')
  },
  {
    //通知详情
    path: '/notice/detail/:id',
    name: 'noticeDetail',
    props: true,
    component: () => import('views/notice/detail.vue')
  },

]

const router = new VueRouter({
  mode: 'hash',
  base: process.env.BASE_URL,
  routes
})

export default router
